﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using StructureMap;
using StructureMap.Configuration.DSL;

namespace Tdv.Wfrp.CharacterGenerator.Client.Bootstrapper
{
    public static class BootstrapFactory
    {
        public static void Bootstrap(IEnumerable<Registry> registries)
        {
            ObjectFactory.Initialize(x =>
            {
                foreach(Registry registry in registries)
                {
                    x.AddRegistry(registry);
                }
                x.AddRegistry<DomainRegistry>();
            });
        }

    }
}
